<%- include header %>
<% if(user.name != details.name) { %>
    <section style="padding: 20px;text-align: center;color: red;">
        非法用户，你企图去修改别人的文章，心真大！！
    </section>
<%}else{%>
    <section class="u_edit_box">
            <div class="">
                <form method="post">
                    <div class="u_e_tb">
                        <input type="text" class="u_e_t" autofocus="autofocus" name="title" value="<%= details.title %>" autocomplete="off" />
                        <div class="u_e_cb">
                            <label>
                                <% if (details.pub == 1) {%>
                                <input type="checkbox" name="pub">
                                <% }else{ %>
                                <input type="checkbox" name="pub" checked="checked">
                                <%}%>
                                &nbsp;&nbsp;不公开
                            </label>
                        </div>
                        <input type="submit" class="u_e_btn" value="保存" />
                    </div>
                    <div class="u_c_b">
                        <textarea name="post" class="u_e_c" id="arContent" ref="arContent"  :style="{height:textHeight+'px'}" @keydown="changeContent"><%- details.post %></textarea>
                        <div class="u_c_show u_ac_main"  id="preArContent" ref="preArContent"  :style="{height:textHeight+'px'}">
                                <%- posthtml %>
                        </div>
                        <a class="iconfont i_markdown" href="https://www.appinn.com/markdown/" target="_blank">&#xf1eb;</a>
                    </div>
                    <div class="clearfix"></div>
                </form>
            </div>
        </section>
<%}%>

<%- include footer2 %>